package ace.cmp.spring.data.jdbc.querydsl.test.core.product.controller;

import ace.cmp.spring.data.jdbc.querydsl.test.core.product.model.dto.Product;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import java.util.Collections;
import java.util.List;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author caspar
 * @date 2023/2/14 10:58
 */
@Tag(name = "商品接口")
@RequestMapping("/product")
@RestController
@RequiredArgsConstructor
public class ProductController {

  @Operation(summary = "搜索商品", description = "")
  @GetMapping("/search")
  public List<Product> search() {
    return Collections.emptyList();
  }

  @Operation(summary = "添加商品", description = "")
  @PostMapping("/add")
  public Product add() {
    return null;
  }
}
